package DSENS;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */



/**
 *
 * @author teeteto
 */
public class Message extends AbstractMessage{

    private int timetolive;
    private int dim;

    public int getTimetolive() {
        return timetolive;
    }

    public void setTimetolive(int timetolive) {
        this.timetolive = timetolive;
    }

    public int getDim() {
        return dim;
    }

    public void setDim(int dim) {
        this.dim = dim;
    }



    public void printMessage() {
        System.out.print("Message# "+this.getID() +"\n");
    }
    
    public Message() {
        super();
        setTimetolive(0);
    }

    public Message(int ttl) {
        super();
        setTimetolive(ttl);
    }

    public Message(int ttl, int dim) {
        super();
        setTimetolive(ttl);
        setDim(dim);
    }


}
